﻿<UserControl x:Class="PwdMgrUI.Search"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
             mc:Ignorable="d" 
             d:DesignHeight="300" d:DesignWidth="300">
    <Grid>
        <Grid.RowDefinitions>
            <RowDefinition Height="*" />
            <RowDefinition Height="6*" />
        </Grid.RowDefinitions>
        
        <StackPanel Grid.Row="0" Orientation="Horizontal">
            <TextBlock Text="Search:" VerticalAlignment="Center"
                       HorizontalAlignment="Right" Style="{StaticResource STBLK_Global}" />
            <TextBox Name="tbox_SearchText" Style="{StaticResource STBOX_Global}" Margin="10,0,0,0" />
            <TextBlock Name="tblk_Loading" Text="Loading..." Visibility="Hidden"
                       Foreground="DarkGray" Margin="10,0,0,0" VerticalAlignment="Center" />
        </StackPanel>
        <Grid Grid.Row="1">
            <DataGrid Name="dg_Content" IsReadOnly="True" AutoGenerateColumns="False"
                      RowHeaderWidth="0">
                <DataGrid.Columns>
                    <DataGridTextColumn Width="*" Header="Username" Binding="{Binding Path=Username}" />
                    <DataGridTemplateColumn Header="Password" Width="*">
                        <DataGridTemplateColumn.CellTemplate>
                            <DataTemplate>
                                <TextBlock Text="{Binding Path=Password}" Name="tblk_RowPassword" MouseLeftButtonDown="Tblk_RowPassword_MouseLeftButtonDown" />
                            </DataTemplate>
                        </DataGridTemplateColumn.CellTemplate>
                    </DataGridTemplateColumn>
                    <DataGridTextColumn Width="*" Header="Tag1" Binding="{Binding Path=Tag1}" />
                    <DataGridTextColumn Width="*" Header="Tag2" Binding="{Binding Path=Tag2}" />
                    <DataGridTextColumn Width="*" Header="Tag3" Binding="{Binding Path=Tag3}" />
                    <DataGridTextColumn Width="*" Header="Tag4" Binding="{Binding Path=Tag4}" />
                    <DataGridTextColumn Width="*" Header="Tag5" Binding="{Binding Path=Tag5}" />
                </DataGrid.Columns>
            </DataGrid>
        </Grid>
    </Grid>
</UserControl>
